<%@ tag body-content="empty"%>
<%@tag import="com.b2c.ftysys.helper.DateUtils"%>
<%@tag import="java.util.Date"%>
<%@tag import="com.b2c.ftysys.constants.FtySysConstants"%>
<%@ attribute name="compareDate" required="true" type="java.util.Date" description="要比较的日期"%>
<%@ attribute name="endDate" type="java.util.Date" description="结束日期，若为空，则设为今天"%>
<%
if(null!=compareDate){
    if(null==endDate){endDate=new Date();}
    int betweenDay = DateUtils.getDaysBetween(endDate,compareDate);
    if(betweenDay>0){
       if(FtySysConstants.DELAY_DAY >= betweenDay){
           if(FtySysConstants.RED_DAY >= betweenDay){
              out.print("red");
           }else{
              out.print("yellow");
           }
       }
    }
}
%>